const { Button, Input, Form, Space } = antd;

/**
 * TestComp 组件
 * 包含多个AI工具按钮和表单功能
 * @param {Object} props - 组件属性
 * @returns {JSX.Element} React 组件
 */
export default function TestComp(props) {
  /**
   * 打开URL处理函数
   * @param {string} url - 要打开的URL地址
   */
  const openUrl = (url) => {
    window.open(url, '_blank');
  };

  return (
    <>
      <Space direction="vertical" size="middle" style={{ width: '100%', padding: '20px' }}>
        {/* AI工具按钮组 */}
        <Space wrap>
          <Button onClick={() => openUrl('https://www.kimi.com/')}>
            kimi
          </Button>
          <Button onClick={() => openUrl('https://chat.deepseek.com/')}>
            deepseek
          </Button>
          <Button onClick={() => openUrl('https://metaso.cn/')}>
            metaso
          </Button>
          <Button onClick={() => openUrl('https://bot.n.cn/chathome')}>
            nami
          </Button>
          <Button onClick={() => openUrl('https://chat.qwen.ai/')}>
            qianwen
          </Button>
          <Button onClick={() => openUrl('https://doubao.com/')}>
            豆包
          </Button>
          <Button onClick={() => openUrl('https://www.coze.cn/')}>
            coze
          </Button>
          <Button onClick={() => openUrl('https://www.baidu.com/')}>
            baidu
          </Button>
        </Space>

        {/* 表单区域 */}
        <Form layout="vertical">
          <Form.Item label="表单输入">
            <Input placeholder="请输入内容" />
          </Form.Item>
        </Form>
      </Space>
    </>
  );
}